#pragma once
#include"RBTree.h"
namespace egghead
{
	template<class T>
	class set
	{
		struct GETVAL{const T& operator()(const T& val) { return val; }};
		typedef typename RBTree<T, const T, GETVAL>::Iterator Iterator;
		typedef typename RBTree<T, const T, GETVAL>::const_Iterator const_Iterator;
		
	public:
		pair<Iterator, bool> insert(const T& data){return _tree.insert(data);}
		void inorder(){_tree.inorder();}
		size_t size() { return _tree.size(); }
		bool checktree() { return _tree.checktree(); }
		Iterator begin() { return _tree.begin(); }
		Iterator end() { return _tree.end(); }
		const_Iterator begin() const { return _tree.begin(); }
		const_Iterator end() const { return _tree.end(); }

	private:
		RBTree < T, const T, GETVAL> _tree;
	};
 }